﻿using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp1
{
    class Program
    {
        static void Main(string[] args)
        {
            ArrayList al = new ArrayList();
            Console.WriteLine("请输入10个，1到10的数字");
            al.Add(50);
            al.Add(60);
            al.Add(80);
            al.Add(90);
            al.Add(10);
            al.Add(20);
            al.Add(30);
            al.Add(40);
            Console.WriteLine("总共的个数"+al.Capacity);
            Console.WriteLine("赋值了；"+al.Count);
            foreach (int i in al)
            {
                Console.Write(i+" ");
            }
            Console.WriteLine();
            al.Sort();
            foreach (int i in al)
            {
                Console.Write(i+" ");
            }
            
        }
    }
}
